import sys
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from PyQt5.QtWidgets import *
from window import Ui_MainWindow
import numpy as np


class MainWidow(QMainWindow, Ui_MainWindow):
    def __init__(self):
        super(MainWidow, self).__init__()
        self.setupUi(self)

        p1 = self.widget.addPlot(title="Basic array plotting",
                                 y=np.random.normal(size=100))

        p2 = self.widget.addPlot(title="Multiple curves")
        p2.plot(np.random.normal(size=100), pen=(255, 0, 0), name="Red curve")
        p2.plot(np.random.normal(size=110) + 5,
                pen=(0, 255, 0),
                name="Green curve")
        p2.plot(np.random.normal(size=120) + 10,
                pen=(0, 0, 255),
                name="Blue curve")

        p3 = self.widget.addPlot(title="Drawing with points")
        p3.plot(np.random.normal(size=100),
                pen=(200, 200, 200),
                symbolBrush=(255, 0, 0),
                symbolPen='w')


if __name__ == "__main__":
    app = QApplication(sys.argv)
    window = MainWidow()
    # form.showFullScreen()
    window.show()
    sys.exit(app.exec_())
